/* stylelint-disable */
@import "../themes/variable";

.top-nav-wrap {
  flex: 1;
  display: flex;
  justify-content: space-between;
}

.top-nav {
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  > li {
    display: inline-block;
    vertical-align: middle;
  }
  .item {
    display: block;
    border-radius: 2px;
    text-align: center;
    line-height: 100%;
    padding: 8px 2px;
    min-width: 50px;
    transition: background-color 300ms;
    cursor: pointer;
    outline: none;
    &:hover {
      background-color: rgba(255, 255, 255, 0.2) !important;
    }
    i {
      font-size: 18px;
      line-height: 100%;
    }
  }
  .top-nav-btn {
    display: $header-item-display !important;
  }
  .item,
  apes-badge {
    color: #fff !important;
  }
}

@media screen and (max-width: $screen-md) {
  .top-nav .top-nav-btn {
    display: block !important;
  }
}



// Search
@mixin header-search-mixin($enabled) {
  @if $enabled == true {
    $header-search-prefix-cls: header-search;
    .#{$header-search-prefix-cls} {
      flex: 1;
      margin: 0 $layout-gutter * 3;
      position: relative;
      display: flex;
      align-items: center;
      .apes-input {
        &:focus {
          box-shadow: none;
        }
      }
      .apes-input,
      .apes-input-group-addon {
        background-color: rgba(255, 255, 255, 0.2);
        color: #fff;
        border: none;
        &::-webkit-input-placeholder {
          color: #fff;
          opacity: 1;
        }
      }
      .apes-input-group-addon {
        i {
          transition: color 300ms, transform 400ms;
          font-size: 18px;
          color: #fff;
        }
      }
      &.#{$header-search-prefix-cls}__focus {
        .apes-input,
        .apes-input-group-addon {
          background-color: #f3f3f3;
          color: $grey-8;
          &::placeholder {
            color: $grey-8;
            opacity: 1;
          }
        }
        .apes-input-group-addon {
          i {
            transform: rotate(180deg);
            color: $grey-8;
            &:before {
              content: '\E61B';
            }
          }
        }
      }
    }

    @media (min-width: $screen-sm) {
      .top-nav .#{$header-search-prefix-cls}__btn {
        display: none;
      }
    }

    @media (max-width: $screen-sm) {
      .#{$header-search-prefix-cls} {
        align-items: center;
        transition: transform 300ms;
        padding: 0 $header-padding;
        margin: 0;
        position: absolute;
        left: 0;
        top: 0;
        height: 100%;
        width: 100%;
        background-color: #fff;
        z-index: $zindex+20;
        &__toggled {
          display: flex;
        }
        &:not(&__toggled) {
          transform: translate3d(0, -105%, 0);
        }
      }
    }
  }
}

@include header-search-mixin($header-search-enabled);
// Collapsed


// Desktop
// @media (min-width: $screen-sm) {}
// Under pad


// APP ICONS
.app-icons {
  padding: $layout-gutter * 2;
  .apes-col-6 {
    padding: ($layout-gutter * 2) 0;
    border-radius: 4px;
    text-align: center;
    transition: background-color 300ms;
    cursor: pointer;
    &:hover {
      background-color: #ececec;
    }
  }
  i {
    border-radius: 50%;
    font-size: 22px;
    padding: 15px;
  }
  small {
    font-size: 14px;
    padding-top: 4px;
    color: #9c9c9c;
    display: block;
  }
}
